class Student:
    def __init__(self,name,age,xingbie,high,zhong,chengji,dizhi,dhhm):
        self.name = name
        self.age = age
        self.xingbie = xingbie
        self.high = high
        self.zhong = zhong
        self.chengji = chengji
        self.dizhi = dizhi
        self.dhhm = dhhm
    def lihai(self,study):
        print(f"{self.name}学习{study}小时")
    def wanyx(self,play):
        print(f"{self.name}在玩{play}")
    def biancheng(self,daima):
        print(f"{self.name}在写{daima}行代码")
    def qh(self,qiuhe):
        print(f"{self.name}在求和{qiuhe}")

Student = Student ("大风车",18,"boy",199,150,100,"河南",177177177)
Student.wanyx('QQ飞车')
Student.lihai(3)
Student.biancheng(9999)
Student.qh(219821989218)

###2车类
class Car:
    def __init__(self,xh,cls,csys,czl,yxdx):
        self.xh = xh
        self.cls = cls
        self.csys = csys
        self.czl = czl
        self.yxdx = yxdx
    def pao(self,gongneng):
        print(f"{self.xh}的{gongneng}能力为重量{self.czl}{self.yxdx}油箱{self.csys}车身")

Car1 = Car ("fll",4,'白色','1010kg','77l')
Car2 = Car ("bm",8,'黑色','1010kg','77l')
Car3 = Car ("lm",6,'绿色','1010kg','77l')
Car4 = Car ("wl",12,'白色','1010kg','77l')
Car5 = Car ("tlj",6,'黑色','1010kg','77l')
Car1.pao('越野')
Car2.pao('越野')

##3笔记本
class bjb:
    def __init__(self,xh,djsj,ys,zl,cpu,neicun,yingpan):
        self.xh = xh
        self.djsj = djsj
        self.ys = ys
        self.zl = zl
        self.cpu = cpu
        self.neicun = neicun
        self.yingpan = yingpan
    def shiyong(self,dyx):
        print(f"{self.xh}的{dyx}能力为{self.cpu}的处理器{self.djsj}的待机时间")
bjb=bjb('dell','9小时','白色','8','i7','8g','512g')
bjb.shiyong("玩cf")

##4猴子
class hozi:
    def __init__(self,lb,xb,stys,tz):
        self.lb = lb
        self.xb = xb
        self.stys = stys
        self.tz = tz
    def zaohuo(self,cailiao):
        print(f"{self.lb}猴子使用{cailiao}造火")
    def xuexi(self,nengli):
        print(f"{self.lb}猴子在学习{nengli}")
hozi=hozi('孙悟空','男','金色','10086kg')
hozi.zaohuo("金箍棒")
hozi.xuexi("玩电脑")



